package darknet.application.chat.impl.net.response;

import darknet.application.chat.spec.Channel;
import darknet.core.spec.net.Response;
import java.util.Set;

/**
 * A response to list channel message.
 *
 * @author Yoyo
 */
public class ListChannelResponse implements Response {

    /** List of channels. */
    private Set<Channel> channels;

    /**
     * Initialise a new ListChannel Response.
     *
     * @param channels The list of all channels.
     */
    public ListChannelResponse(Set<Channel> channels) {

        if (channels == null) {
            throw new IllegalArgumentException("channels is null");
        }
        this.channels = channels;
    }

    public Set<Channel> getChannels() {
        return channels;
    }

}
